<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib uri="/struts-tags" prefix="s" %>
<!DOCTYPE html>
<html>
<head>
  <title>部门信息</title>
  <style type="text/css">
    table {
      border-collapse: collapse;
      width: 75%;
      border: 1px solid;
    }
    td {
      border: 1px solid
    }
  </style>
</head>
<body>
<div align="center">
  <s:include value="add.jsp" />
  <s:a href="position">职位信息</s:a>
  <s:a href="employee">员工信息</s:a>
  <table>
    <tr>
      <th>部门id</th>
      <th>部门名称</th>
      <th>操作</th>
    </tr>
    <s:if test="departments.size>0">
      <s:iterator value="departments" var="department">
        <tr>
          <td><s:property value="#department.departmentId" /></td>
          <td><s:property value="#department.departmentName" /></td>
          <td>
            <s:a href="department!edit.action?department.departmentId=%{#department.departmentId}">编辑</s:a>
            <s:a href="department!remove.action?department.departmentId=%{#department.departmentId}">移除</s:a>
          </td>
        </tr>
      </s:iterator>
    </s:if>
  </table>
</div>
</body>
</html>
